// component/logistics-tpl/logistics-tpl.js
Component({

  /**
   * 组件的属性列表
   */
  properties: {
    logisticsInfo: {
      type: Object,
      value: null
    },
    show: {
      type: Boolean,
      value: false
    },
    onText: {
      type: String,
      value: '确定'
    },
    userType: {
      type: String,
      value: null
    }
  },

  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    /**
     * 取消弹窗
     */
    cancelLogistics() {
      this.triggerEvent('cancelPopup');
    },

    /**
     * 提交物流信息
     */
    submitLogistics(e) {
      const value = e.detail.value;
      this.triggerEvent('updateLogistics', { logisticsInfo: value });
    }
  }
})